package com.ruoyi.sl.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.sl.mapper.SlDeductionMapper;
import com.ruoyi.sl.domain.SlDeduction;
import com.ruoyi.sl.service.ISlDeductionService;

/**
 * 扣款相关人Service业务层处理
 * 
 * @author admin
 * @date 2024-06-27
 */
@Service
public class SlDeductionServiceImpl implements ISlDeductionService 
{
    @Autowired
    private SlDeductionMapper slDeductionMapper;

    /**
     * 查询扣款相关人
     * 
     * @param deductionId 扣款相关人主键
     * @return 扣款相关人
     */
    @Override
    public SlDeduction selectSlDeductionByDeductionId(Long deductionId)
    {
        return slDeductionMapper.selectSlDeductionByDeductionId(deductionId);
    }

    /**
     * 查询扣款相关人列表
     * 
     * @param slDeduction 扣款相关人
     * @return 扣款相关人
     */
    @Override
    public List<SlDeduction> selectSlDeductionList(SlDeduction slDeduction)
    {
        return slDeductionMapper.selectSlDeductionList(slDeduction);
    }

    /**
     * 新增扣款相关人
     * 
     * @param slDeduction 扣款相关人
     * @return 结果
     */
    @Override
    public int insertSlDeduction(SlDeduction slDeduction)
    {
        return slDeductionMapper.insertSlDeduction(slDeduction);
    }

    /**
     * 修改扣款相关人
     * 
     * @param slDeduction 扣款相关人
     * @return 结果
     */
    @Override
    public int updateSlDeduction(SlDeduction slDeduction)
    {
        return slDeductionMapper.updateSlDeduction(slDeduction);
    }

    /**
     * 批量删除扣款相关人
     * 
     * @param deductionIds 需要删除的扣款相关人主键
     * @return 结果
     */
    @Override
    public int deleteSlDeductionByDeductionIds(Long[] deductionIds)
    {
        return slDeductionMapper.deleteSlDeductionByDeductionIds(deductionIds);
    }

    /**
     * 删除扣款相关人信息
     * 
     * @param deductionId 扣款相关人主键
     * @return 结果
     */
    @Override
    public int deleteSlDeductionByDeductionId(Long deductionId)
    {
        return slDeductionMapper.deleteSlDeductionByDeductionId(deductionId);
    }
}
